package com.tengfei.main.plan.service;

import com.tengfei.common.core.domain.PageQuery;
import com.tengfei.common.core.page.TableDataInfo;
import com.tengfei.main.course.domain.vo.CourseVo;
import com.tengfei.main.plan.domain.bo.PlanBo;
import com.tengfei.main.plan.domain.bo.PlanCoursesBo;
import com.tengfei.main.plan.domain.bo.PlanUsersBo;
import com.tengfei.main.plan.domain.vo.PlanCoursesVo;
import com.tengfei.main.plan.domain.vo.PlanSimpleVo;
import com.tengfei.main.plan.domain.vo.PlanUsersVo;
import com.tengfei.main.plan.domain.vo.PlanVo;

import java.util.Collection;
import java.util.List;

/**
 * 学习计划Service接口
 *
 * @author tengfei
 * @date 2022-08-01
 */
public interface IPlanService {

    /**
     * 查询学习计划
     */
    PlanVo queryById(Long planId);

    /**
     * 查询学习计划列表
     */
    TableDataInfo<PlanVo> queryPageList(PlanBo bo, PageQuery pageQuery);


    /**
     * 修改学习计划
     */
    Boolean insertByBo(PlanBo bo);

    /**
     * 修改学习计划
     */
    Boolean updateByBo(PlanBo bo);

    /**
     * 校验并批量删除学习计划信息
     */
    Boolean deleteWithValidByIds(Collection<Long> ids);

    Boolean openPlan(Long id);

    Boolean closePlan(Long id);

    Boolean insertPlanCourseByBos(List<PlanCoursesBo> bos);

    Boolean insertPlanUserByBos(List<PlanUsersBo> bos);

    Boolean deletePlanCourseByIds(List<Long> ids);

    Boolean deletePlanUserByIds(List<Long> ids);

    List<PlanCoursesVo> queryPlanCourseList(Long id);


    TableDataInfo<PlanUsersVo> queryPlanUserList(PlanUsersBo planUsersBo, PageQuery pageQuery);

    TableDataInfo<CourseVo> queryPlanCourseListUnBind(Long id, String courseName, PageQuery pageQuery);

    TableDataInfo<PlanUsersVo> queryPlanUserListUnBind(PlanUsersBo planUsersBo, PageQuery pageQuery);

    List<PlanSimpleVo> querySimpleList(String planName);
}
